package com.bbs.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.bbs.dto.CategoryAdd;
import com.bbs.pojo.Category;
import com.bbs.pojo.Result;

import java.util.List;
import java.util.Map;

public interface ICategoryService extends IService<Category> {

    /**
     * 添加板块接口
     * @param categoryAdd
     * @return
     */
    Result<Object> addCategory(CategoryAdd categoryAdd) throws Exception;

    /**
     * 根据标签名字搜索板块
     * @return
     */
    Result<Map<String, List<Category>>> groupByTag();

    Result<Category> getCategory(String id);
}
